package com.hyts.distlock.lock;



/**
 * project-name:coffice-toolbox
 * package-name:com.hyts.distlock.lock
 * author:Libo/Alex
 * create-date:2019-05-10 22:23
 * copyright:libo-hyts-github
 * email:libo2dev@aliyun.com
 * description:此类主要用于: zookeeper 客户端的相关连接数据对象
 */
public abstract class ZookeeperLock<T> extends BaseLock<T> {

    /**
     * Lock对象构造器
     *
     * @param lockObjectClient
     */
    public ZookeeperLock(T lockObjectClient) {
        super(lockObjectClient);
    }

    public abstract boolean tryLock(String lockName, Long timeout);

    public abstract boolean tryLock(String lockName);

    public abstract boolean unlock(String lockName);
}
